<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>WLog: XmlOuter.h源文件</title>
<link href="tabs.css" rel="stylesheet" type="text/css">
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- 制作者 Doxygen 1.5.8 -->
<script type="text/javascript">
<!--
function changeDisplayState (e){
  var num=this.id.replace(/[^[0-9]/g,'');
  var button=this.firstChild;
  var sectionDiv=document.getElementById('dynsection'+num);
  if (sectionDiv.style.display=='none'||sectionDiv.style.display==''){
    sectionDiv.style.display='block';
    button.src='open.gif';
  }else{
    sectionDiv.style.display='none';
    button.src='closed.gif';
  }
}
function initDynSections(){
  var divs=document.getElementsByTagName('div');
  var sectionCounter=1;
  for(var i=0;i<divs.length-1;i++){
    if(divs[i].className=='dynheader'&&divs[i+1].className=='dynsection'){
      var header=divs[i];
      var section=divs[i+1];
      var button=header.firstChild;
      if (button!='IMG'){
        divs[i].insertBefore(document.createTextNode(' '),divs[i].firstChild);
        button=document.createElement('img');
        divs[i].insertBefore(button,divs[i].firstChild);
      }
      header.style.cursor='pointer';
      header.onclick=changeDisplayState;
      header.id='dynheader'+sectionCounter;
      button.src='closed.gif';
      section.id='dynsection'+sectionCounter;
      section.style.display='none';
      section.style.marginLeft='14px';
      sectionCounter++;
    }
  }
}
window.onload = initDynSections;
-->
</script>
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>首页</span></a></li>
      <li><a href="namespaces.html"><span>名字空间</span></a></li>
      <li><a href="annotated.html"><span>类</span></a></li>
      <li class="current"><a href="files.html"><span>文件</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>文件列表</span></a></li>
      <li><a href="globals.html"><span>文件成员</span></a></li>
    </ul>
  </div>
<h1>XmlOuter.h</h1><a href="XmlOuter_8h.html">浏览该文件的文档。</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="preprocessor">#ifndef _WLOG_XML_H_</span>
<a name="l00002"></a>00002 <span class="preprocessor"></span><span class="preprocessor">#define _WLOG_XML_H_</span>
<a name="l00003"></a>00003 <span class="preprocessor"></span>
<a name="l00004"></a>00004 <span class="preprocessor">#include &lt;ostream&gt;</span>
<a name="l00005"></a>00005 
<a name="l00006"></a>00006 <span class="preprocessor">#include "<a class="code" href="IOuter_8h.html">IOuter.h</a>"</span>
<a name="l00007"></a>00007 
<a name="l00008"></a>00008 <span class="keyword">using</span> std::ostream;
<a name="l00009"></a>00009 
<a name="l00010"></a>00010 <span class="keyword">namespace </span>WLog
<a name="l00011"></a>00011 {
<a name="l00012"></a>00012     <span class="keyword">class </span>Record;
<a name="l00013"></a>00013     <span class="keyword">class </span>ILevel;
<a name="l00017"></a><a class="code" href="classWLog_1_1XmlOuter.html">00017</a>     <span class="keyword">class </span><a class="code" href="classWLog_1_1XmlOuter.html" title="对IOuter实现xml格式输出">XmlOuter</a> : <span class="keyword">public</span> <a class="code" href="classWLog_1_1IOuter.html" title="Interface for output Record with define Log Level.">IOuter</a>
<a name="l00018"></a>00018     {
<a name="l00019"></a>00019     <span class="keyword">public</span>:
<a name="l00020"></a>00020         <a class="code" href="classWLog_1_1XmlOuter.html#599f7b0d650781bc2e3aff560db0a236">XmlOuter</a>(ostream &amp;<a class="code" href="classWLog_1_1XmlOuter.html#7a8c4c8fe086ddd6b3432763f1f11d6b" title="输出strOutLevel.">out</a>, <span class="keyword">const</span> <span class="keywordtype">char</span>* szEncode);
<a name="l00021"></a>00021         <span class="keyword">virtual</span> <a class="code" href="classWLog_1_1XmlOuter.html#90404a79802c009a16bcf1fa4fb0ec98">~XmlOuter</a>();
<a name="l00022"></a>00022 
<a name="l00023"></a>00023     <span class="keyword">public</span>:
<a name="l00027"></a>00027         <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classWLog_1_1XmlOuter.html#8da830dd28b2e209b207dbe366f946ba" title="通知Outer准备要输出了, 做一些事前的工作，如XML可以在这里输出其申明。...">noticeParpareOut</a>();
<a name="l00028"></a>00028         
<a name="l00032"></a>00032         <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classWLog_1_1XmlOuter.html#f900b7a0f69de8a3d08ca40b7043c7c7" title="通知结束输出，做一些输出事后工作，如XML可以在这里输出根结点的结尾。...">noticeEndOut</a>();
<a name="l00033"></a>00033 
<a name="l00041"></a>00041         <span class="keywordtype">bool</span> <a class="code" href="classWLog_1_1XmlOuter.html#44bc2cb7e627fad755175ffd1a5f608b" title="输出Record记录与Record对应的Level.">outRecord</a>(<a class="code" href="classWLog_1_1Record.html" title="记录类，记录一条信息的所有字段。">Record</a> *pRecord, <a class="code" href="classWLog_1_1ILevel.html" title="Define Interface for Log Level.">ILevel</a> *pLevel);
<a name="l00042"></a>00042 
<a name="l00049"></a>00049         <span class="keywordtype">bool</span> <a class="code" href="classWLog_1_1XmlOuter.html#7a8c4c8fe086ddd6b3432763f1f11d6b" title="输出strOutLevel.">out</a>(<span class="keywordtype">string</span> strOut);
<a name="l00050"></a>00050 
<a name="l00056"></a>00056         <span class="keywordtype">bool</span> <a class="code" href="classWLog_1_1XmlOuter.html#cf344873172b152c53c41c67d9772d7f" title="输出换行符.">outendl</a>();
<a name="l00057"></a>00057     
<a name="l00058"></a>00058     <span class="keyword">private</span>:
<a name="l00065"></a>00065         <span class="keywordtype">void</span> outNode(<span class="keywordtype">string</span> strNodeName, <span class="keywordtype">string</span> strContext);
<a name="l00066"></a>00066 
<a name="l00073"></a>00073         <span class="keywordtype">string</span> encode2XmlData(<span class="keywordtype">string</span> strContext);
<a name="l00074"></a>00074 
<a name="l00075"></a>00075     <span class="keyword">private</span>:
<a name="l00076"></a>00076         <a class="code" href="classWLog_1_1XmlOuter.html" title="对IOuter实现xml格式输出">XmlOuter</a> &amp; operator=( <span class="keyword">const</span> <a class="code" href="classWLog_1_1XmlOuter.html" title="对IOuter实现xml格式输出">XmlOuter</a> &amp; ) { <span class="keywordflow">return</span> *<span class="keyword">this</span>; } <span class="comment">// for warning C4512 when L4</span>
<a name="l00077"></a>00077 
<a name="l00078"></a>00078     <span class="keyword">protected</span>:
<a name="l00079"></a><a class="code" href="classWLog_1_1XmlOuter.html#273b855c9c5dd52d4a2d9a2871e3d854">00079</a>         ostream &amp;<a class="code" href="classWLog_1_1XmlOuter.html#273b855c9c5dd52d4a2d9a2871e3d854">m_out</a>;
<a name="l00080"></a><a class="code" href="classWLog_1_1XmlOuter.html#34da0715e59a44c5c8308a55e5adbd4a">00080</a>         std::string <a class="code" href="classWLog_1_1XmlOuter.html#34da0715e59a44c5c8308a55e5adbd4a">strEncode</a>;
<a name="l00081"></a>00081     };
<a name="l00082"></a>00082 }
<a name="l00083"></a>00083 
<a name="l00084"></a>00084 <span class="preprocessor">#endif //_WLOG_XML_H_</span>
</pre></div></div>
<hr>
<address style="align: right;">
  Generated on Mon Apr 6 21:08:12 2009 for WLog by 韦体东<img src="logo.png" align="middle"/></address>
</body>
</html>
